<template>
	<view>
		<page-head :title="'考试标准'" :headtype="2"></page-head>
		<view class="ruleblock marginAuto">
			<view class="rulebtn mainBg baiColor marginAuto">考试标准</view>
			<view class="ruletxt">
				<uv-parse :content="content"></uv-parse>
			</view>
			<!-- <view class="ruletext">
				<view class="ruletexteach">
					<view class="ruletext-title">一、考试内容</view>
					<view class="ruletext-txt">科目一考试为理论考试，主要考查道路交通安全法律、法规和相关知识，内容包括道路交通安全法规、交通信号、安全行车文明驾驶基础知识、机动车驾驶操作相关基本知识、交通事故救护常识等</view>
				</view>
			</view> -->
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				apifun:this.apifun,
				km:'',
				content:''
			};
		},
		onLoad(option) {
			this.km = option.km;
			this.initData()
		},
		methods: {
			initData(){
				let key = '';
				if(this.km == 1){
					key = '科目一考试标准'
				}else if(this.km == 2){
					key = '科目二考试标准'
				}else if(this.km == 3){
					key = '科目三考试标准'
				}else if(this.km == 4){
					key = '科目四考试标准'
				}
				let sendData = {
					key:key
				};
				this.apifun.unirequest('/api/index/getContent','post',sendData,(res)=>{
					if(res.code === 200){
						let datas = res.data;
						this.content = datas.content;
					}else{
						this.apifun.toast(res.msg)
					}
				})
			}
		},
	};
</script>

<style scoped lang="scss">
	.ruleblock{
		width: 650rpx;
		padding:30rpx 20rpx;
		border-radius: 20rpx;
		background: #fff;
		margin-top: 20rpx;
	}
	.rulebtn{
		width: 440rpx;
		height: 90rpx;
		line-height: 90rpx;
		text-align: center;
		border-radius: 100rpx;
		margin-top: 30rpx;
	}
	.ruletxt{
		margin-top: 20rpx;
		font-size: 28rpx;
		color: #333333;
		line-height: 50rpx;
	}
	// ui布局
	.ruletext{
		margin-top: 20rpx;
		.ruletexteach{
			margin-top: 20rpx;
			.ruletext-title{
				color: #222222;
				font-size: 30rpx;
				font-weight: 600;
				margin-bottom: 20rpx;
			}
			.ruletext-txt{
				color: #333333;
				font-size: 28rpx;
			}
		}
	}
</style>